<?php
echo "<div id=\"debug\">";
echo "<h3>Debug info</h3>";
echo "<div id=\"debuginfo\">";

echo "<h4>Edition mode?</h4>";
echo $editMode ? "Yes" : "No";

echo "<h4>Is mobile?</h4>";
echo $detect->isMobile() ? "Yes" : "No";

if($detect->isMobile()){
  if ($detect->isAndroid()) {
      echo "<pre> - Android</pre>";
  }
  if ($detect->isBlackberry()) {
      echo "<pre> - Blackberry</pre>";
  }
  if ($detect->isIphone()) {
      echo "<pre> - Iphone</pre>";
  }
  if ($detect->isIpad()) {
      echo "<pre> - Ipad</pre>";
  }
  if ($detect->isOpera()) {
      echo "<pre> - Opera</pre>";
  }
  if ($detect->isPalm()) {
      echo "<pre> - Palm</pre>";
  }
  if ($detect->isWindows()) {
      echo "<pre> - Windows</pre>";
  }
  if ($detect->isGeneric()) {
      echo "<pre> - Generic</pre>";
  }
}

echo "<h4>User agent</h4>";
echo "<pre>" . $_SERVER['HTTP_USER_AGENT'] . "</pre>";

echo "<h4>User browser</h4>";
echo "<pre>" . browserDetect() . "</pre>";

if(browserDetect() == "MSIE"){
  echo "<h4>IE version</h4>";
  echo "<pre>" . ieversion() . "</pre>";
}

echo "<h4>CSS browser</h4>";
echo "<pre>" . $cssBrowser . "</pre>";

echo "<h4>Request URI</h4>";
echo "<pre>" . htmlspecialchars($_SERVER['REQUEST_URI']) . "</pre>";


echo "<h4>Joomla lang</h4>";
echo $activeLang;

echo "<h4>Frontpage or not?</h4>";
echo $isFrontpage ? "Yes" : "No";


echo "<h4>Session vars</h4>";
echo "<pre>";
print_r($_SESSION);  
echo "</pre>";

echo "<h4>Cookie vars</h4>";
echo "<pre>";
print_r($_COOKIE);
echo "</pre>";

echo "</div>";
echo "</div>";